﻿//
// Copyright (c) 2024 BPer
//

#include <bperencoder/BPerVideoEncoder.h>


BPerVideoEncoder::BPerVideoEncoder() {
	m_isInit=0;
	memset(&m_videoInfo,0,sizeof(BPerVideoInfo));
	m_vbuffer=new uint8_t[BPER_VIDEO_ENCODE_BUFFER_LEN];
}

BPerVideoEncoder::~BPerVideoEncoder() {
	if(m_vbuffer) delete m_vbuffer;
	m_vbuffer=NULL;
}

void BPerVideoEncoder::setVideoPara(BPerVideoInfo *pap,BPerVideoEncInfo *penc){
	memcpy(&m_videoInfo,pap,sizeof(BPerVideoInfo));
	memcpy(&m_enc,penc,sizeof(BPerVideoEncInfo));
}

